package com.nd.android.u.ui.messageCreator;

import android.content.Context;

import com.nd.android.u.controller.innerInterface.IChatListItem;
import com.nd.android.u.controller.innerInterface.IMessageDisplay;
import com.nd.android.u.controller.outInterface.IMessageCreator;
import com.nd.android.u.ui.activity.message_chat.ChatActivity_App;
import com.nd.android.u.ui.beanStarApp.DisplayMessage_App;
import com.nd.android.u.ui.widge.ChatListItemView_App;

/**
 * 默认的应用消息生产者
 * <br>Created 2014-9-18 下午5:52:04
 * @version  
 * @author   cb		
 * @see 	 
 */
public class DefaultAppMessageCreator implements IMessageCreator  {
	@Override
	public Class<?> getDisplayClass(IMessageDisplay message) {
		return ChatActivity_App.class;
	}

	@Override
	public IMessageDisplay getMessageDisplay(int appid,String appcode) {
		DisplayMessage_App app=new DisplayMessage_App();
		app.appCode=appcode;
		app.appId=appid;
		return app;
	}

	@Override
	public IChatListItem getMessageView(Context context, IMessageDisplay message, boolean getParentOnly) {
		IChatListItem item = new ChatListItemView_App(context);
		return item;
	}
}
